package com.weifangfirecontrolformal.weifangfirecontrolformal.web.web.business.businessdetail;

import cn.hutool.json.JSONObject;
import com.weifangfirecontrolformal.weifangfirecontrolformal.common.base.BaseController;
import com.weifangfirecontrolformal.weifangfirecontrolformal.support.annotaion.Action;
import com.weifangfirecontrolformal.weifangfirecontrolformal.support.annotaion.At;
import com.weifangfirecontrolformal.weifangfirecontrolformal.support.model.RespEntity;
import com.weifangfirecontrolformal.weifangfirecontrolformal.web.service.business.businessdetail.BusinessDetailService;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;

import javax.annotation.Resource;

/**
 * 单位详情控制器
 */
@Action
@RequestMapping(value="business/businessDetail")
public class BusinessDetailController extends BaseController {
    @Resource
    public BusinessDetailService businessDetailService;

    /**
     * 详情页面数据统计
     * @param
     * businessId	单位id：如果是机构用户登录需要传,如果是单位用户自己取
     * @return
     */
    @At(value = "statistics", method = RequestMethod.GET)
    public RespEntity statistics(@RequestBody(required = false) JSONObject jsonParam) {
        return businessDetailService.statistics(jsonParam);
    }
   
}